using System;
using System.Data;
using System.Configuration;
using System.Collections;
using System.Web;
using System.Web.Security;
using System.Web.UI;
using System.Web.UI.WebControls;
using System.Web.UI.WebControls.WebParts;
using System.Web.UI.HtmlControls;

public partial class GUI_Webpage_MasterTunga : System.Web.UI.MasterPage
{
    FoodBll foodBll = new FoodBll();
    FoodInfo foodInfo = new FoodInfo();
    RestaurantInfo resInfo = new RestaurantInfo();
    RestaurantBll resBll = new RestaurantBll();
    public string selectSearch = null;

    protected void Page_Load(object sender, EventArgs e)
    {

    }
    protected void btnSearch_Click(object sender, EventArgs e)
    {
        selectSearch = rbSelect.SelectedValue.ToString();
        
        if (selectSearch == "Food")
        {
            foodInfo.FoodName = txtSearch.Text;
            
            string link = "Result.aspx?foodName=" + foodInfo.FoodName + "&select="+ selectSearch +"";
            Response.Redirect(link);
        }
        else
        {
            resInfo.ResName = txtSearch.Text;
            string link = "Result.aspx?resName=" + resInfo.ResName + "&select=" + selectSearch + "";
            Response.Redirect(link);
        }

    }

    
}
